<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<style>
    .box {
        position: absolute;
        width: 200px;
        height: 100px;
        left: 50%;
        top: 50%;
        transform: translate(-50%, -50%);
        background-color: pink;

    }
</style>
<body>
    <div class="box"></div>
</body>
</html>